package com.example.bbs.agent.lazy.dao;

import com.example.bbs.agent.lazy.model.User;
import com.example.bbs.dao.BaseDao;

/**
 * author: VC
 * create: 2021/7/16 10:24
 * version: 1.0.0
 */
public class UserDaoImpl extends BaseDao implements UserDao{
    @Override
    public User findById(int uid) {
        return null;
    }
//    @Override
//    public User findById(int uid) {
//        return (User) find("select * from user where id = ?", rs -> {
//            if(rs.next()) {
//                return createUser(rs);
//            }
//            return null;
//        }, uid);
//    }
//
//    private User createUser(ResultSet rs) throws SQLException {
//        return new User(
//                rs.getInt("id"),
//                rs.getString("name"),
//                rs.getString("pwd"));
//    }
}
